﻿using System;
using System.Web.UI;
using visinia.SmartEngine;
using visinia.SmartEngine.Modules;

public partial class Modules_General_HtmlBox_HtmlBox : WebModule
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            LiteralControl lc = new LiteralControl((string)Settings["HTML"]);
            PlaceHolderHTML.Controls.Add(lc);
        }
        if (WebModuleController.CURRENT_MODE == WebModuleController.MODES.DESIGNER)
        {
            WebPageController.AddScriptLink(Page, WebRoots.GetJsRoot + "Editors/jHtmlArea/jHtmlArea-0.7.0.min.js");
            WebPageController.AddCssLink(Page, WebRoots.GetJsRoot + "Editors/jHtmlArea/style/jHtmlArea.css");
            WebPageController.AddScriptLink(Page, WebRoots.GetAdminScriptsRoot + "Editors/visinia-editor.js");
        }
    }
}
